package com.wzy.service.schedule.service.impl;

import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.wzy.service.schedule.entity.Schedule;
import com.wzy.service.schedule.mapper.ScheduleMapper;
import com.wzy.service.schedule.service.ScheduleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author wuzhengyu
 * @since 2021-03-31
 */
@Service
public class ScheduleServiceImpl extends ServiceImpl<ScheduleMapper, Schedule> implements ScheduleService {
    @Autowired
    ScheduleMapper scheduleMapper;
    /**
     * 组装schedule的内容
     * @param uid
     * @return
     */
    @Override
    public Schedule getSchedule(String uid) {
        return scheduleMapper.selectOne(Wrappers.<Schedule>lambdaQuery().eq(Schedule::getUid, uid));
    }
}
